package com.jzsk.variable.center.zhengxin.controller;

import com.jzsk.variable.center.domain.dto.login.LoginReqDTO;
import com.jzsk.variable.center.domain.dto.login.LoginRespDTO;
import com.jzsk.variable.center.domain.vo.ResponseVO;
import com.jzsk.variable.center.service.login.LoginService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @author jiangli
 */
@RestController
@Api(tags = "登录操作")
public class LoginController {

    @Resource
    LoginService loginService;

    @PostMapping("/login")
    @ApiOperation(value = "登录操作", notes = "登录操作")
    public ResponseVO<LoginRespDTO> login(@RequestBody LoginReqDTO loginReqDTO) {
        return loginService.login(loginReqDTO);
    }

}
